﻿@{
    Layout = "~/Areas/Admin/Views/Shared/_Layout.cshtml";
}
@section JsHeader{
    <script type="text/javascript" src="/areas/admin/js/user.js"></script>
}
<table>
    <thead>
        <tr>
            <th>
                用户名
            </th>
            <th>
                操作
            </th>
        </tr>
    </thead>
    <tbody>
        @{
            int index = 0;
            foreach (dynamic user in ViewBag.Users)
            {
                if (index % 2 == 0)
                {
            <tr>
                <td>@user.UserName
                </td>
                <td>
                   <input type="button" value="删除" onclick="doDelete(@user.UserId);" />
                </td>
            </tr>
                }
                else
                {
            <tr class="alt-row">
                <td>@user.UserName
                </td>
                <td>
                   <input type="button" value="删除" onclick="doDelete(@user.UserId);" />
                </td>
            </tr>
                }
                index++;
            }
        }
    </tbody>
</table>